/*
 * @Description: 
 * @Author: HKH
 * @Date: 2024-09-20 08:39:40
 * @LastEditors: HKH
 * @LastEditTime: 2024-09-20 10:00:13
 */
public class Mao extends Animal{
    private String type;
    public Mao(){

    }
    public Mao(String color,int age,String type){
        super(color,age);
        this.type=type;
    }
    @Override
    public void eat(){
        System.out.println("猫吃鱼");
    }
    @Override
    public void sleep(){
        System.out.println("猫睡觉");
    }
    @Override
    public String toString(){
        
        String str="猫的类型："+this.type+"猫的颜色："+getColor()+"年龄："+getAge();
        return str;

    }
}